﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Nina
{
    /// <summary>
    /// Abstract class for protocol handlers
    /// Copyright 2011 Thomas Cashman
    /// </summary>
    public abstract class NinaProtocolHandler
    {
        /// <summary>
        /// Called when a session is opened
        /// </summary>
        /// <param name="s"></param>
        public abstract void SessionOpened(NinaSession s);

        /// <summary>
        /// Called when a session is closed
        /// </summary>
        /// <param name="s"></param>
        public abstract void SessionClosed(NinaSession s);

        /// <summary>
        /// Called when a message is received
        /// </summary>
        /// <param name="s"></param>
        /// <param name="data"></param>
        public abstract void MessageReceived(NinaSession s, byte [] data);
    }
}
